// 引入用户集合
const User = require("../../model/user");
module.exports = async(req, res) => {
    const { uid } = req.body;
    const resData = {
        data: {},
        meta: {
            code: 200,
            msg: "查找成功!",
        },
    };
    let user = await User.findOne({ _id: uid });
    if (user != null) {
        resData.data = user;
        res.send(resData);
    } else {
        resData.meta.code = 400;
        resData.meta.msg = "您搜索的内容不存在!";
        res.send(resData);
    }
};